﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using FluentNHibernate.Mapping;

namespace Mindfor.Web.Modules.Catalog
{
	public class ProductImageMap : ClassMap<ProductImage>
	{
		public ProductImageMap()
		{
			Table("ProductImages");
			Id(m => m.Id);
			Map(m => m.Picture).CustomSqlType("image").Length(int.MaxValue).Nullable();
			Map(m => m.Sort);
			References<Product>(r => r.Product, "ProductId");
		}
	}
}